CPAP machine with MNT algorithm